home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Internet Info 1994 March
/
Internet Info CD-ROM (Walnut Creek) (March 1994).iso
/
networking
/
ip
/
ka9q
/
alpha.arc
/
ASYVEC.ASM
< prev
next >
Wrap
Assembly Source File
|
1987-12-22
|
3KB
|
167 lines
include lmacros.h
assume ds:dataseg
public sssave,spsave,intstk,doret
ifdef FARPROC
extrn doret:far,asyint_:far,getintds:far
else
extrn doret:near,asyint_:near,getintds:near
endif
; asy0vec - asynch channel 0 interrupt handler
public asy0vec_
asy0vec_ proc far
push ds ; save on user stack
call getintds ; establish interrupt data segment
mov ds:sssave,ss ; stash user stack context
mov ds:spsave,sp
push ds
pop ss
lea sp,intstk+512
push ax ; save user regs on interrupt stack
push bx
push cx
push dx
push bp
push si
push di
push es
push ds
pop es ; set up es reg, so di can be used!!
mov ax,0 ; arg for service routine
push ax
call asyint_
pop ax
jmp doret
asy0vec_ endp
; asy1vec - asynch channel 1 interrupt handler
public asy1vec_
asy1vec_ proc far
push ds ; save on user stack
call getintds ; establish interrupt data segment
mov ds:sssave,ss ; stash user stack context
mov ds:spsave,sp
push ds
pop ss
lea sp,intstk+512
push ax ; save user regs on interrupt stack
push bx
push cx
push dx
push bp
push si
push di
push es
push ds
pop es ; set up es reg, so di can be used!!
mov ax,1 ; arg for service routine
push ax
call asyint_
pop ax
jmp doret
asy1vec_ endp
; asy2vec - asynch channel 2 interrupt handler
public asy2vec_
asy2vec_ proc far
push ds ; save on user stack
call getintds ; establish interrupt data segment
mov ds:sssave,ss ; stash user stack context
mov ds:spsave,sp
push ds
pop ss
lea sp,intstk+512
push ax ; save user regs on interrupt stack
push bx
push cx
push dx
push bp
push si
push di
push es
push ds
pop es ; set up es reg, so di can be used!!
mov ax,2 ; arg for service routine
push ax
call asyint_
pop ax
jmp doret
asy2vec_ endp
; asy3vec - asynch channel 3 interrupt handler
public asy3vec_
asy3vec_ proc far
push ds ; save on user stack
call getintds ; establish interrupt data segment
mov ds:sssave,ss ; stash user stack context
mov ds:spsave,sp
push ds
pop ss
lea sp,intstk+512
push ax ; save user regs on interrupt stack
push bx
push cx
push dx
push bp
push si
push di
push es
push ds
pop es ; set up es reg, so di can be used!!
mov ax,3 ; arg for service routine
push ax
call asyint_
pop ax
jmp doret
asy3vec_ endp
; asy4vec - asynch channel 4 interrupt handler
public asy4vec_
asy4vec_ proc far
push ds ; save on user stack
call getintds ; establish interrupt data segment
mov ds:sssave,ss ; stash user stack context
mov ds:spsave,sp
push ds
pop ss
lea sp,intstk+512
push ax ; save user regs on interrupt stack
push bx
push cx
push dx
push bp
push si
push di
push es
push ds
pop es ; set up es reg, so di can be used!!
mov ax,4 ; arg for service routine
push ax
call asyint_
pop ax
jmp doret
asy4vec_ endp
end